翻訳と辞書
Words near each other
・ chorus
・ christmas tree
・ christmas tree packet
・ christopher strachey
・ chromatic number
・ chrome
・ chroot
・ chrp
・ chug
・ chunker
church integer
・ church of the subgenius
・ church, alonzo
・ church-rosser theorem
・ ci
・ ci$
・ cicero
・ cichlid
・ cics
・ cid


Dictionary Lists
翻訳と辞書 辞書検索 [ 開発暫定版 ]
スポンサード リンク

church integer : FOLDOC
Church integer
A representation of integers as functions invented by Alonzo Church, inventor of lambda-calculus. The integer N is represented as a higher-order function which applies a given function N times to a given expression. In the pure lambda-calculus there are no constants but numbers can be represented by Church integers.
A Haskell function to return a given Church integer could be written:
church n = c
where
c f x = if n == 0 then x else c' f (f x)
where
c' = church (n-1)

A function to turn a Church integer into an ordinary integer:
unchurch c = c (+1) 0

See also von Neumann integer.
(1994-11-29)



スポンサード リンク
翻訳と辞書 : 翻訳のためのインターネットリソース

Copyright(C) kotoba.ne.jp 1997-2016. All Rights Reserved.